package scau.erps.service.impl;

import java.util.List;

import org.nutz.dao.Cnd;
import org.nutz.dao.util.cri.SqlExpressionGroup;
import org.nutz.service.IdEntityService;

import scau.erps.entity.Score;
import scau.erps.service.ScoreService;

public class ScoreServiceImpl extends IdEntityService<Score> implements ScoreService{

	@Override
	public List<Score> getScore(int team_id) {
		SqlExpressionGroup e1 = null;
		if(team_id != 0){
			e1 = Cnd.exps("team_Id", "=", team_id);			
		}
		return this.query(Cnd.where(e1), null);
	}

	@Override
	public void updateScore(Score score) {
		this.dao().update(score);
		
	}

}
